# Real mode 
# phy addr = CS << 4  + IP
BOOTSEG=0x07c0
.code16
.text

.global _start

_start:
	# BOOTSEG -> CS, start2 -> IP
	# jump to where ???
	jmpl $BOOTSEG, $start2 

start2:
	# what about this do ?
	movw $BOOTSEG, %ax
	movw %ax, %ds
	movw %ax, %es
	movw %ax, %fs
	movw %ax, %gs
	
	movw $msg, %ax
	movw %ax, %bp       # bp : base pointer
	movw $0x01301, %ax  # what about this ??
	movw $0x0c, %bx     # bx : base reg 
	movw $12, %cx		# cx : counter reg
	movb $0, %dl   		# 
	int $0x010          # interrupt 10h ??


loop:
	jmp loop # does this work ??

msg:
	.ascii "hello world"

.org 510  # what's this ??

boot_flag:
	.word 0xaa55